/*******************************************************************************
 * Package: com.practice.web
 * Type:    JsonResult
 * Date:    2023/9/26 13:48
 *
 * Copyright (c) 2023 HUANENG GUICHENG TRUST CORP.,LTD All Rights Reserved.
 *
 * You may not use this file except in compliance with the License.
 *******************************************************************************/
package com.practice.web;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * 统一配置的响应类
 *
 * @author Masiyu
 * @date 2023/9/26 13:48
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class JsonResult<T> implements Serializable {
    private Integer code = 200;
    private String message = "成功";
    private T data;
    
    public JsonResult(T data){
        this.data = data;
    }
    public JsonResult(Integer code,String message){
        this.code = code;
        this.message = message;
    }
}
